#ifndef MUSIC_H
#define MUSIC_H

#include <QWidget>
#include <QMouseEvent>

QT_BEGIN_NAMESPACE
namespace Ui { class Music; }
QT_END_NAMESPACE

class Music : public QWidget
{
    Q_OBJECT

public:
    Music(QWidget *parent = nullptr);
    ~Music();

    //无边框窗口设置函数
    void InitUI();

protected:
    //重写QWidget类的鼠标单击和鼠标滚轮事件
    void mousePressEvent(QMouseEvent *event) override;
    void mouseMoveEvent(QMouseEvent *event) override;

    //记录光标相对于窗口标题栏的相对距离
    QPoint dragPosition;

private:
    Ui::Music *ui;
};
#endif // MUSIC_H
